home *** CD-ROM | disk | FTP | other *** search
/ Amiga Format CD 52 / Amiga Format AFCD52 (Issue 136, May 2000).iso / -serious- / programming / c / stormamiga_lib-v45_00d / include / assert.h < prev    next >
C/C++ Source or Header  |  2000-02-28  |  604b  |  34 lines

  1. #ifndef _INCLUDE_ASSERT_H
  2. #define _INCLUDE_ASSERT_H
  3.  
  4. /*
  5. **  $VER: assert.h 1.02 (7.2.97)
  6. **  StormC Release 3.0
  7. **
  8. **  '(C) Copyright 1995/96/97 Haage & Partner Computer GmbH'
  9. **       All Rights Reserved
  10. */
  11.  
  12. #ifdef NDEBUG
  13. #define assert(C)
  14. #else
  15. #ifdef __cplusplus
  16. extern "C" {
  17. #endif
  18. void do_assert(char *, char *, char *, unsigned int);
  19. #ifdef __cplusplus
  20. }
  21. #endif
  22. #define assert(C) { if(!(C)) do_assert(#C, __FILE__, __FUNC__, __LINE__); }
  23. #endif
  24.  
  25. /*----- support for stormamiga.lib -----*/
  26.  
  27. #ifdef STORMAMIGA
  28.   #ifndef  ASSERT_STORMAMIGA_H
  29.     #include <assert_stormamiga.h>
  30.   #endif
  31. #endif
  32.  
  33. #endif
  34.